<template>
	<div class="swiper-container">
		<!-- 滑动内容区域 -->
		<div class="swiper-wrapper">
			<!-- 滑动项 -->
			<div class="swiper-slide" v-for='(item,index) in swiperList' :key='item.id'>
				<img :src="item.imgURL" />
			</div>
		</div>
	</div>
</template>

<script>
	//导入swiper插件
	import Swiper from 'swiper';
	export default{
		props:['swiperList'],
		data(){
			return{
				/* swiperOptions:{}, */
			}
		},
		updated(){
			new Swiper ('.swiper-container',{
				//重复滑动
				loop:true,
				observer:true,
				observeParents:true
			});
		}
		
	}
</script>

<style scoped >
	.swiper-container{
		width: 90%;
		height: 3.5rem; /* 209px*/
		margin-top: 0.2rem;
	}
	.swiper-slide img{
		width: 100%;
		height: 100%;
	}
</style>

